<?php

class SettingController extends BackEndController{
	/**
	 * List all settings and updates them if changed
	 */
	public function actionIndex()
	{
	    $model = new SettingForm;
	    
		// collect user input data
		if(isset($_POST['SettingForm']))
		{
			$model->attributes=$_POST['SettingForm'];
			$model->save();
		}
		// display the login form
		$this->render('index',array('model'=>$model));
	}
}